package com.itheima.service;

import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.context.annotation.Lazy;
import org.springframework.stereotype.Service;

//@Lazy
@Service
public class ServiceA {
//    @Autowired
//    private ServiceB serviceB;  // 原本@Lazy可以解决循环依赖, 但是CommonConfig立即调用了方法, 破坏了@Lazy的作用

    public void testA(){
//        serviceB.testB();
        System.out.println("A");
    }
}
